/**
 * There are <a href="https://github.com/thinkgem/jeesite">JeeSite</a> code generation
 */
package com.chlitina.store.modules.message.entity;

import com.chlitina.store.common.persistence.BaseEntity;
import com.chlitina.store.modules.sys.entity.Store;

/**
 * 客户采纳护理项目复合主键
 * @author lvbo
 * @version 2013-06-20
 */
public class SystemNotifyStorePK extends BaseEntity {
	
	private static final long serialVersionUID = 1L;
	private SystemNotifyMessage systemNotifyMessage; 		// 通知消息
	private Store store; 	//门店

	public SystemNotifyStorePK() {
	}

	public SystemNotifyMessage getSystemNotifyMessage() {
		return systemNotifyMessage;
	}

	public void setSystemNotifyMessage(SystemNotifyMessage systemNotifyMessage) {
		this.systemNotifyMessage = systemNotifyMessage;
	}

	public Store getStore() {
		return store;
	}

	public void setStore(Store store) {
		this.store = store;
	}

	@Override
	public int hashCode() {
		return this.systemNotifyMessage.hashCode() + this.store.hashCode();
	}

	@Override
	public boolean equals(Object obj) {
		if (this == obj)
			return true;
		if (obj == null)
			return false;
		if (getClass() != obj.getClass())
			return false;
		final SystemNotifyStorePK other = (SystemNotifyStorePK) obj;
		if (systemNotifyMessage.getId() == other.getSystemNotifyMessage().getId() &&
				store.getId() == other.getStore().getId()) {
			return true;
		} 
		return false;
	}
}